package ink.tiptop.dto.req.base.server;

import com.fasterxml.jackson.annotation.JsonProperty;
import ink.tiptop.annotation.EnumValue;
import lombok.Getter;
import lombok.Setter;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotEmpty;
import javax.validation.constraints.NotNull;
import java.io.Serializable;
import java.util.List;

/**
 * 服务器基本连接信息(ZjfBaseServerInfoEntity)实体类
 *
 * @author makejava
 * @since 2020-06-21 20:40:28
 */
@Getter
@Setter
public class ExportRequest implements Serializable {
    private static final long serialVersionUID = 562641425358423142L;

    /**
     * 导出类型
     * JSON, XML, CSV, TXT, SQL, EXCEL
     */
    @JsonProperty("EXPORT_TYPE")
    @NotBlank(message = "导出类型不能为空")
    @EnumValue(strValues = {"JSON","XML","CSV","TXT","SQL","EXCEL"})
    private String exportType;

    /**
     * 导出的场景
     *
     */
    @JsonProperty("EXPORT_SCENE")
    @NotNull(message = "导出场景不能为空")
    @EnumValue(strValues = {"BASE_SERVER_INFO"})
    private String exportScene;

    /**
     * 需要删除的数据的主键,这里用String统一接收,
     * 如果后面是Integer就转换一下
     */
    @JsonProperty("IDS")
    @NotEmpty(message = "批量删除的ID不能为空")
    private List<String> id;
}